package com.stronger.pettern.decorator.decorator1;

public class PetterDecorator implements Person{

    Petter petter=null;

    public PetterDecorator(){
        petter=new Petter();
    }
    @Override
    public void eat() {
        wash();
        petter.eat();
        sleep();
    }

    public void sleep(){
        System.out.println("sleep,eating after");
    }

    public void wash(){
        System.out.println("wash,eating before");
    }
}
